package pq4;

public class Resumen extends ThreadOperacion implements Runnable{

	protected CuentaCorriente ce;
	protected CajaAhorro ca;
	protected VistaMenu vm;
	
	
	public Resumen(Operacion op,VistaMenu vm) {
		super(op,vm);
		this.thread = new Thread (this,"Resumen");
		this.thread.start();		
	}

	@SuppressWarnings({ "static-access", "deprecation" })
	public void run() {
		int i = 0;
		while (true){
						
			this.thread = Thread.currentThread();
			
			if (this.thread.getName().equals("Resumen")){
				this.lecturaOp();	
				try {
					this.thread.sleep(IThreadOperacion.ESPERA_MAXIMA);				
					
				} catch (InterruptedException e) {
					// TODO Auto-generated catch block
					e.printStackTrace();
				}
			}
			if (i==10){
				this.thread.stop();
			}
			i++;
			System.out.println("lala");
		}
		
		
			
		
		
		
	}
	

}
